﻿using System;
using System.Collections;

namespace SharpSqlAnalyzer.nodes
{
	// Token: 0x02000331 RID: 817
	public class TParseTreeNodeList : TParseTreeNode, IEnumerable
	{
		// Token: 0x06001D6A RID: 7530 RVA: 0x00333618 File Offset: 0x00331818
		IEnumerator IEnumerable.GetEnumerator()
		{
			return this.v.GetEnumerator();
		}

		// Token: 0x170006D2 RID: 1746
		// (get) Token: 0x06001D6B RID: 7531 RVA: 0x00333625 File Offset: 0x00331825
		public int Count
		{
			get
			{
				return this.size();
			}
		}

		// Token: 0x06001D6C RID: 7532 RVA: 0x0033362D File Offset: 0x0033182D
		public int size()
		{
			return this.v.Count;
		}

		// Token: 0x06001D6D RID: 7533 RVA: 0x0033363A File Offset: 0x0033183A
		public virtual TParseTreeNode elementAt(int index)
		{
			return (TParseTreeNode)this.v[index];
		}

		// Token: 0x06001D6E RID: 7534 RVA: 0x0033364D File Offset: 0x0033184D
		internal void remove(int index)
		{
			this.v.Remove(index);
		}

		// Token: 0x06001D6F RID: 7535 RVA: 0x00333660 File Offset: 0x00331860
		internal int indexOf(TParseTreeNode ptn)
		{
			return this.v.IndexOf(ptn);
		}

		// Token: 0x06001D70 RID: 7536 RVA: 0x0033366E File Offset: 0x0033186E
		internal void setElementAt(TParseTreeNode ptn, int index)
		{
			this.v[index] = ptn;
		}

		// Token: 0x06001D71 RID: 7537 RVA: 0x0033367D File Offset: 0x0033187D
		public override void init(object arg1)
		{
			this.addParseTreeNode(arg1);
		}

		// Token: 0x06001D72 RID: 7538 RVA: 0x00333686 File Offset: 0x00331886
		internal virtual void addParseTreeNode(object arg1)
		{
			this.addElement((TParseTreeNode)arg1);
		}

		// Token: 0x06001D73 RID: 7539 RVA: 0x00333694 File Offset: 0x00331894
		public void insertElementAt(TParseTreeNode ptn, int index)
		{
			this.v.Insert(index, ptn);
		}

		// Token: 0x06001D74 RID: 7540 RVA: 0x003336A3 File Offset: 0x003318A3
		public virtual void addNode(object arg1)
		{
			this.addParseTreeNode((TParseTreeNode)arg1);
		}

		// Token: 0x06001D75 RID: 7541 RVA: 0x003336B1 File Offset: 0x003318B1
		public void addElement(TParseTreeNode ptn)
		{
			this.v.Add(ptn);
		}

		// Token: 0x06001D76 RID: 7542 RVA: 0x003336C0 File Offset: 0x003318C0
		public void removeElementAt(int index)
		{
			this.v.RemoveAt(index);
		}

		// Token: 0x06001D77 RID: 7543 RVA: 0x003336CE File Offset: 0x003318CE
		public void removeElement(TParseTreeNode ptn)
		{
			this.v.Remove(ptn);
		}

		// Token: 0x06001D78 RID: 7544 RVA: 0x003336DC File Offset: 0x003318DC
		public virtual TParseTreeNode getElement(int index)
		{
			return this.elementAt(index);
		}

		// Token: 0x06001D79 RID: 7545 RVA: 0x003336E8 File Offset: 0x003318E8
		public override void doParse(TCustomSqlStatement psql, ESqlClause plocation)
		{
			for (int i = 0; i < this.size(); i++)
			{
				if (this.elementAt(i) != null)
				{
					this.elementAt(i).doParse(psql, plocation);
				}
			}
		}

		// Token: 0x06001D7A RID: 7546 RVA: 0x0033371D File Offset: 0x0033191D
		public override TSourceToken getStartToken()
		{
			if (this.size() == 0)
			{
				return null;
			}
			return this.elementAt(0).getStartToken();
		}

		// Token: 0x06001D7B RID: 7547 RVA: 0x00333735 File Offset: 0x00331935
		public override TSourceToken getEndToken()
		{
			if (this.size() == 0)
			{
				return null;
			}
			return this.elementAt(this.size() - 1).getEndToken();
		}

		// Token: 0x04001AAB RID: 6827
		private ArrayList v = new ArrayList();
	}
}
